package com.dianping.cat.home.heartbeat.entity;

import com.dianping.cat.home.heartbeat.BaseEntity;
import com.dianping.cat.home.heartbeat.IVisitor;



public class Metric
  extends BaseEntity<Metric>
{
  private String m_id;
/*  12 */   private String m_unit = "1";

  private boolean m_delta = false;

  private int m_order;

  private String m_title;

  private String m_lable = "MB";



  private boolean m_alert = false;



/*  28 */   public Metric(String id) { this.m_id = id; }




/*  33 */   public void accept(IVisitor visitor) { visitor.visitMetric(this); }



  public boolean equals(Object obj) {
/*  38 */     if (obj instanceof Metric) {
/*  39 */       Metric _o = (Metric)obj;

/*  41 */       if (!equals(getId(), _o.getId())) {
/*  42 */         return false;
      }

/*  45 */       return true;
    }

/*  48 */     return false;
  }


/*  52 */   public boolean getAlert() { return this.m_alert; }



/*  56 */   public boolean getDelta() { return this.m_delta; }



/*  60 */   public String getId() { return this.m_id; }



/*  64 */   public String getLable() { return this.m_lable; }



/*  68 */   public int getOrder() { return this.m_order; }



/*  72 */   public String getTitle() { return this.m_title; }



/*  76 */   public String getUnit() { return this.m_unit; }



  public int hashCode() {
/*  81 */     int hash = 0;

/*  83 */     return hash * 31 + ((this.m_id == null) ? 0 : this.m_id.hashCode());
  }




/*  89 */   public boolean isAlert() { return this.m_alert; }



/*  93 */   public boolean isDelta() { return this.m_delta; }



  public void mergeAttributes(Metric other) {
/*  98 */     assertAttributeEquals(other, "metric", "id", this.m_id, other.getId());

/* 100 */     if (other.getUnit() != null) {
/* 101 */       this.m_unit = other.getUnit();
    }

/* 104 */     this.m_delta = other.getDelta();

/* 106 */     this.m_order = other.getOrder();

/* 108 */     if (other.getTitle() != null) {
/* 109 */       this.m_title = other.getTitle();
    }

/* 112 */     if (other.getLable() != null) {
/* 113 */       this.m_lable = other.getLable();
    }

/* 116 */     this.m_alert = other.getAlert();
  }

  public Metric setAlert(boolean alert) {
/* 120 */     this.m_alert = alert;
/* 121 */     return this;
  }

  public Metric setDelta(boolean delta) {
/* 125 */     this.m_delta = delta;
/* 126 */     return this;
  }

  public Metric setId(String id) {
/* 130 */     this.m_id = id;
/* 131 */     return this;
  }

  public Metric setLable(String lable) {
/* 135 */     this.m_lable = lable;
/* 136 */     return this;
  }

  public Metric setOrder(int order) {
/* 140 */     this.m_order = order;
/* 141 */     return this;
  }

  public Metric setTitle(String title) {
/* 145 */     this.m_title = title;
/* 146 */     return this;
  }

  public Metric setUnit(String unit) {
/* 150 */     this.m_unit = unit;
/* 151 */     return this;
  }

  public Metric() {}
}


/* Location:              /Users/hanfei/Documents/apache-tomcat-9.0.24/webapps/cat/WEB-INF/classes/!/com/dianping/cat/home/heartbeat/entity/Metric.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       1.0.7
 */